<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="js/vue.js"></script>
    <style>
        *{
            margin: 0;
            padding: 0;
            list-style: none;
        }
        .item{
            background-color: black;
        }
        .success{
            color:green
        }
    </style>
</head>
<body>
    <div id="app">
        <div :class="myclass">样式的测试</div>
        <div :class="myclass1">样式的测试</div>
        <div :class="[myclass2,default1]">测试样式</div>
        <div :class="flag?'success':'error'">测试样式</div>
        <hr/>
        <div style="background-color: red;color: black;">测试style</div>
        <div :style="mystyle1">测试style</div>

    </div>
</body>
<script>
    new  Vue({
        el:"#app",
        data:{
            flag:true,
            myclass:"success",
            myclass1:{
                success:false
            },
            myclass2:"success",
            default1:"item"

        }
    })
</script>
</html>